<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>写博客</title>
  <link rel="shortcut icon" href="../../static/images/icon.icon" type="image/x-icon">
  <link rel="stylesheet" href="../../static/bootstrap-3.3.7-dist/css/bootstrap.min.css">
  <link rel="stylesheet" href="../../static/edit.md/editormd.min.css">
  <script src="../../static/bootstrap-3.3.7-dist/js/jquery.min3.5.js"></script>
  <script src="../../static/bootstrap-3.3.7-dist/js/bootstrap.min.js"></script>
  <script src="../../static/edit.md/editormd.min.js"></script>
</head>
<body>
<div id="layout">
  <div id="test-editormd">
    <textarea style="display:none;">
    </textarea>
  </div>
</div>

<script type="text/javascript">
    var testEditor;
    $(function () {
        testEditor = editormd("test-editormd", {
            width: "100%",
            height: 670,
            syncScrolling: "single",
            path: "../../static/edit.md/lib/",
        });
    });
</script>
<script>
    [].slice.call( document.querySelectorAll( 'button.progress-button' ) ).forEach( function( bttn ) {
        new ProgressButton( bttn, {
            callback : function( instance ) {
                var progress = 0,
                    interval = setInterval( function() {
                        progress = Math.min( progress + Math.random() * 0.1, 1 );
                        instance._setProgress( progress );

                        if( progress === 1 ) {
                            instance._stop(1);
                            clearInterval( interval );
                        }
                    }, 200 );
            }
        } );
    } );
</script>
</body>
</html>